﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Data.OleDb;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Text;
using wzwebsite;
using System.Web.SessionState;


public partial class contactus : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            if (Request["dd"] != null)
            {
                TextBox1.Text = "我对贵公司的" + Request["dd"] + "感兴趣";
            }
        }
    }
    protected void Button2_Click(object sender, EventArgs e)
    {
        string strsql = "insert into guestbook(title,lianxiren,email,tel,content,compamyname,site,fax) values" + "(" + "'" + TextBox1.Text.Trim() + "'," + "'" + TextBox2.Text.Trim() + "'," + "'" + TextBox3.Text.Trim() + "'," + "'" + TextBox4.Text.Trim() + "'," + "'" + TextArea1.Value.Trim() + "'," + "'" + TextBox5.Text.Trim() + "'," + "'" + TextBox6.Text.Trim() + "'," + "'" + TextBox7.Text.Trim() + "'" + ")";
        sqlhelper.ExecuteNonQuery(CommandType.Text, strsql, null);
        sqlhelper.alert("提交成功");
    }
}
